package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.AppointmentMapper;
import com.ruoyi.system.domain.Appointment;
import com.ruoyi.system.service.IAppointmentService;

/**
 * 预约订单Service业务层处理
 * 
 * @author 何志龙
 * @date 2024-09-21
 */
@Service
public class AppointmentServiceImpl implements IAppointmentService 
{
    @Autowired
    private AppointmentMapper appointmentMapper;

    /**
     * 查询预约订单
     * 
     * @param id 预约订单主键
     * @return 预约订单
     */
    @Override
    public Appointment selectAppointmentById(Long id)
    {
        return appointmentMapper.selectAppointmentById(id);
    }

    /**
     * 查询预约订单列表
     * 
     * @param appointment 预约订单
     * @return 预约订单
     */
    @Override
    public List<Appointment> selectAppointmentList(Appointment appointment)
    {
        return appointmentMapper.selectAppointmentList(appointment);
    }

    /**
     * 新增预约订单
     * 
     * @param appointment 预约订单
     * @return 结果
     */
    @Override
    public int insertAppointment(Appointment appointment)
    {
        return appointmentMapper.insertAppointment(appointment);
    }

    /**
     * 修改预约订单
     * 
     * @param appointment 预约订单
     * @return 结果
     */
    @Override
    public int updateAppointment(Appointment appointment)
    {
        return appointmentMapper.updateAppointment(appointment);
    }

    /**
     * 批量删除预约订单
     * 
     * @param ids 需要删除的预约订单主键
     * @return 结果
     */
    @Override
    public int deleteAppointmentByIds(Long[] ids)
    {
        return appointmentMapper.deleteAppointmentByIds(ids);
    }

    /**
     * 删除预约订单信息
     * 
     * @param id 预约订单主键
     * @return 结果
     */
    @Override
    public int deleteAppointmentById(Long id)
    {
        return appointmentMapper.deleteAppointmentById(id);
    }
}
